package com.dao.impl.mapper;

import java.sql.ResultSet;
import java.sql.SQLException;

import org.springframework.jdbc.core.RowMapper;

import com.modelo.Marca;

public class MarcaMapper implements RowMapper{

	@Override
	public Object mapRow(ResultSet rs, int num_rows) throws SQLException {
		Marca marca = new Marca();
		try{
			marca.setId(rs.getInt(1));
			marca.setNombre(rs.getString(2));
		}catch(Exception e){
			System.out.println("ModeloMapper Errror: "+e.getMessage());
		}
		return marca;
	}
	
}